import { createApp } from "vue";
import App from "./App.vue";
import router from "@/router";
import ElementPlus from "element-plus";
import pinia from "@/store/index";
import { Events } from "@/utils/events_bus";
import { useIndexStore } from '@/store/model';
import resize_directive from "@/utils/resize_directive/index.js"; // 引入自定义指令
import "@/assets/css/init.css";
import "@/assets/font/iconfont.css";
import "element-plus/dist/index.css";

let app = createApp(App)
	.use(router)
	.use(pinia)
	.use(ElementPlus)
	.directive("resize", resize_directive);
Events.IPC.Renderer.on("send_param", (e, params) => {
    const store = useIndexStore()
    store.set_param(params)
});
app.mount("#app");
